﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.Objects;
using TrainigWorkshop.Model;


namespace TrainigWorkshop.DAL_EF
{
    public class ClassRespository_EF :IClassRespository
    {   
        public List<Grade> GetClassInfo()
        {
            using (projectbEntities edm = new projectbEntities())
            {
                List<Class> grade = (from c in edm.Classes select c).ToList<Class>();

                List<Grade> gradeChange = ModelTranslation.ClassEFTranslator.ToClassModel(grade);
                return gradeChange;
            }
        }

    }
}
